import request from '@/utils/request'

// Query class list
export function listClass(query) {
  return request({
    url: '/education/class/list',
    method: 'get',
    params: query
  })
}

// Query class details
export function getClass(id) {
  return request({
    url: '/education/class/' + id,
    method: 'get'
  })
}

// Add class
export function addClass(data) {
  return request({
    url: '/education/class',
    method: 'post',
    data: data
  })
}

// Modify class
export function updateClass(data) {
  return request({
    url: '/education/class',
    method: 'put',
    data: data
  })
}

// Delete class
export function delClass(id) {
  return request({
    url: '/education/class/' + id,
    method: 'delete'
  })
}

// Get class options for select
export function listClassOptions() {
  return request({
    url: '/education/class/options',
    method: 'get'
  })
}
